﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Data;


namespace IEWebSite.Administration
{
    public partial class EditCurs : BaseEditControl
    {
        #region Events
        #endregion

        protected override void SetBindings()
        {
            //LC Test If Event Occurs During DataBound Event
            if (DataItem != null && DataItem.GetType() == typeof(System.Data.DataRowView))
            {
                Descriere.Content = (String)((DataRowView)DataItem)["Descriere"];
                DescriereEN.Content = (String)((DataRowView)DataItem)["DescriereEN"];
                txtTitlu.Text = (String)((DataRowView)DataItem)["Titlu"];
                txtTitluEN.Text = (String)((DataRowView)DataItem)["TitluEN"];
                ddlC.SelectedValue = ((Int32)((DataRowView)DataItem)["NrC"]).ToString();
                ddlS.SelectedValue = ((Int32)((DataRowView)DataItem)["NrS"]).ToString();
                ddlLP.SelectedValue = ((Int32)((DataRowView)DataItem)["NrLP"]).ToString();
                ddlNrPuncteCredit.SelectedValue = ((Int32)((DataRowView)DataItem)["PuncteCredit"]).ToString();
                ddlSemestru.SelectedValue = ((Int32)((DataRowView)DataItem)["Semestru"]).ToString();
                ddlAnStudiu.SelectedValue = ((Int32)((DataRowView)DataItem)["AnStudiu"]).ToString();
                ddlCategorie.SelectedValue = ((Int32)((DataRowView)DataItem)["IdSysCategorieDisciplina"]).ToString();
                ddlTipDisciplina.SelectedValue = ((Int32)((DataRowView)DataItem)["IdSysTipDisciplina"]).ToString();
                ddlPlanInv.SelectedValue = ((Int32)((DataRowView)DataItem)["IdPlanInvatamant"]).ToString();
                ddlCiclu.SelectedValue = ((Int32)((DataRowView)DataItem)["IdCiclu"]).ToString();
            }
        }
    }
}